import os,sys,random,pygame,math
from pygame.locals import *
import cPickle as pickle

import screen,levelcontroller,interactive_world

def load_image(name,colorkey):
    fullname = os.path.join('data','pictures',name)
    i=pygame.image.load(fullname)
    if colorkey==0:
        colorkey=None
    if colorkey is not None:
        if colorkey is -1:
            colorkey = i.get_at((0,0))
        i.set_colorkey(colorkey, RLEACCEL)
    return i.convert()

control = levelcontroller.LevelController

class W1L1(control):
    def __init__(self):
        image = load_image('W1L1.png',0)
        blocktype = {}
        specials = [interactive_world.Tutorial_Sign((3*64,4*64),['This is a message box',
                                             'They are a great help to',
                                             'Get used to the game.',
                                             'Use the arrow keys to move.',
                                             'Press -Enter- to return to game.'])
                    ]
        text = []
        pos = (2*64,3*64)
        control.__init__(self,image,'W1',blocktype,specials,text,pos)

class W1L2(control):
    def __init__(self):
        image = load_image('W1L2.png',0)
        blocktype = {}
        specials = []
        text = []
        pos = (3*64,17*64)
        control.__init__(self,image,'W1',blocktype,specials,text,pos)
